{% extends "base/base.html" %}

{% block title %}Production / Label Info For {{ object.name }}{% endblock %}

{% block main %}
{% load dv_extend %}<h2><img class="icon_header" {% if object.label_icon %}src="{{ object.label_icon.url }}"{% else %}src="{{ MEDIA_URL }}transmit_blue.png"{% endif %} alt="" />Label / Production Information For {{ object.name }} {% if user.is_staff %} [<a href="/admin/webview/label/{{ object.id }}/">Edit Info</a>]{% endif %}</h2>

<table>
<tr>
<td class="label_summary">
{% if object.logo %}<img class="label_logo" src="{{ object.logo.url }}" />{% else %}<img class="label_logo" src="{{ MEDIA_URL }}no_picture.png" />{% endif %}
<br /><strong>{{ object.name }}</strong><br />
{% if object.found_date %}(Founded On: {{object.found_date|date:"F j, Y" }})<br />{% endif %}
{% if object.cease_date %}Shutdown Date: {{ object.cease_date }}<br />{% endif %}

Links:{% if object.webpage %} <a href="{{ object.webpage }}" target="_blank">[Website]</a>{% endif %}
{% if object.wiki_link %} <a href="{{ object.wiki_link }}" target="_blank">[Wiki]</a>{% endif %}
{% if object.hol_id %} <a href="http://hol.abime.net/hol_search.php?N_ref_developer={{ object.hol_id }}" target="_blank">[HOL]</a>{% endif %}
{% if object.pouetid %} <a href="http://www.pouet.net/groups.php?which={{ object.pouetid }}" target="_blank">[Pouet]</a>{% endif %}
<br />

{% if object.last_updated %}Last Updated: {{ object.last_updated|date:"F j, Y" }}<br />{% endif %}
{% if object.created_by %}Added By: {% with object.created_by as U %}{% include "webview/t/user.html" %}{% endwith %}<br />{% endif %}
</td>
<td class="label_description">
{% if object.info %}
<p><i>{{ object.info|urlize|bbcode|linebreaks }}</i></p>
{% endif %}<br />

{% ifnotequal object.artist_set.count 0 %}
 <b>Associated Artists:</b><br />
 {% for artist in object.artist_set.all %}
  {% with artist as A %}{% include "webview/t/artist.html" %}{% endwith %}<br />
 {% endfor %}<br />
{% endifnotequal %}

{% ifnotequal object.get_songs.count 0 %}
 <b>Associated Songs:</b><br />
 {% for song in object.get_songs.all %}
  {% include "webview/t/songname.html" %} by {% for artist in song.artists.all %}{% with artist as A%}{% include "webview/t/artist.html" %}{% endwith %}{% if forloop.last %} {% else %}, {% endif %} {% endfor %}
  <span data-name="a_queue_{{ song.id }}">{% include "webview/t/songlist_span_noauth.html" %}</span><br />
 {% endfor %}<br />
{% endifnotequal %}
</td>
</tr>
</table>
{% endblock %}
